package com.jack.rpc;

import com.jack.rpc.entity.Student;
import com.jack.rpc.intf.StudentService;
import com.jack.rpc.proxy.RpcClient;

import java.net.InetSocketAddress;

/**
 * Hello world!
 */
public class App {
    public static void main(String[] args) {
        RpcClient rpcClient = new RpcClient();
        StudentService studentService = rpcClient.getProxy(StudentService.class, new InetSocketAddress("localhost", 12345));
        Student student = studentService.findById(1);
        System.out.println("client:findById: " + student.toString());
    }
}
